#include"tcpserver.hpp"
#include<memory>

using namespace std;


int main(int argc, char* argv[])
{

    if (argc != 2)
    {
        cout << "Usage: ./main serverport!" << endl;
        exit(1);
    }

    uint16_t port = stoi(argv[1]);

    unique_ptr<server> svr(new server(port));
    svr->Init();
    svr->run();
    return 0;
}